<?php
// +----------------------------------------------------------------------
// | 管理后台路由配置
// +----------------------------------------------------------------------

use think\facade\Route;

// ==================================================
//                      公共功能模块 - 视图路由
// ==================================================

// 账号登录
Route::any('/api/admin/login', 'admin.Login/login')->allowCrossDomain();
// 账号登出
Route::get('/api/admin/logout', 'admin.Login/logout')->allowCrossDomain();
// 找回密码
Route::get('/api/admin/forgotpassword', 'admin.Login/forgotpassword')->allowCrossDomain();

// 上传文件
Route::any('/api/admin/upload', 'admin.Uploader/upload')->allowCrossDomain();

// ==================================================
//                      公共功能模块 - 数据路由
// ==================================================

// 获取后台菜单数据
Route::any('/api/admin/menu', 'admin.Index/menu')->allowCrossDomain();

// 获取后台起始页数据
Route::any('/api/admin/main', 'admin.Index/main')->allowCrossDomain();


// ==================================================
//                      数据路由
// ==================================================

Route::get('/api/admin/auth-admins/index', 'admin.AuthAdmins/index')->allowCrossDomain();
Route::get('/api/admin/auth-admins/read', 'admin.AuthAdmins/read')->allowCrossDomain();
Route::post('/api/admin/auth-admins/save', 'admin.AuthAdmins/save')->allowCrossDomain();
Route::put('/api/admin/auth-admins/update', 'admin.AuthAdmins/update')->allowCrossDomain();
Route::delete('/api/admin/auth-admins/delete', 'admin.AuthAdmins/delete')->allowCrossDomain();

Route::get('/api/admin/auth-groups/index', 'admin.AuthGroups/index')->allowCrossDomain();
Route::get('/api/admin/auth-groups/read', 'admin.AuthGroups/read')->allowCrossDomain();
Route::post('/api/admin/auth-groups/save', 'admin.AuthGroups/save')->allowCrossDomain();
Route::put('/api/admin/auth-groups/update', 'admin.AuthGroups/update')->allowCrossDomain();
Route::delete('/api/admin/auth-groups/delete', 'admin.AuthGroups/delete')->allowCrossDomain();

Route::get('/api/admin/auth-rules/index', 'admin.AuthRules/index')->allowCrossDomain();
Route::get('/api/admin/auth-rules/read', 'admin.AuthRules/read')->allowCrossDomain();
Route::post('/api/admin/auth-rules/save', 'admin.AuthRules/save')->allowCrossDomain();
Route::put('/api/admin/auth-rules/update', 'admin.AuthRules/update')->allowCrossDomain();
Route::delete('/api/admin/auth-rules/delete', 'admin.AuthRules/delete')->allowCrossDomain();

Route::get('/api/admin/sys-configs/index', 'admin.SysConfigs/index')->allowCrossDomain();
Route::get('/api/admin/sys-configs/read', 'admin.SysConfigs/read')->allowCrossDomain();
Route::post('/api/admin/sys-configs/save', 'admin.SysConfigs/save')->allowCrossDomain();
Route::put('/api/admin/sys-configs/update', 'admin.SysConfigs/update')->allowCrossDomain();
Route::delete('/api/admin/sys-configs/delete', 'admin.SysConfigs/delete')->allowCrossDomain();

Route::get('/api/admin/sys-config-groups/index', 'admin.SysConfigGroups/index')->allowCrossDomain();
Route::get('/api/admin/sys-config-groups/read', 'admin.SysConfigGroups/read')->allowCrossDomain();
Route::post('/api/admin/sys-config-groups/save', 'admin.SysConfigGroups/save')->allowCrossDomain();
Route::put('/api/admin/sys-config-groups/update', 'admin.SysConfigGroups/update')->allowCrossDomain();
Route::delete('/api/admin/sys-config-groups/delete', 'admin.SysConfigGroups/delete')->allowCrossDomain();

Route::get('/api/admin/sys-crontabs/index', 'admin.SysCrontabs/index')->allowCrossDomain();
Route::get('/api/admin/sys-crontabs/read', 'admin.SysCrontabs/read')->allowCrossDomain();
Route::post('/api/admin/sys-crontabs/save', 'admin.SysCrontabs/save')->allowCrossDomain();
Route::put('/api/admin/sys-crontabs/update', 'admin.SysCrontabs/update')->allowCrossDomain();
Route::delete('/api/admin/sys-crontabs/delete', 'admin.SysCrontabs/delete')->allowCrossDomain();

Route::get('/api/admin/sys-email-captchas/index', 'admin.SysEmailCaptchas/index')->allowCrossDomain();
Route::get('/api/admin/sys-email-captchas/read', 'admin.SysEmailCaptchas/read')->allowCrossDomain();
Route::post('/api/admin/sys-email-captchas/save', 'admin.SysEmailCaptchas/save')->allowCrossDomain();
Route::put('/api/admin/sys-email-captchas/update', 'admin.SysEmailCaptchas/update')->allowCrossDomain();
Route::delete('/api/admin/sys-email-captchas/delete', 'admin.SysEmailCaptchas/delete')->allowCrossDomain();

Route::get('/api/admin/sys-sms-captchas/index', 'admin.SysSmsCaptchas/index')->allowCrossDomain();
Route::get('/api/admin/sys-sms-captchas/read', 'admin.SysSmsCaptchas/read')->allowCrossDomain();
Route::post('/api/admin/sys-sms-captchas/save', 'admin.SysSmsCaptchas/save')->allowCrossDomain();
Route::put('/api/admin/sys-sms-captchas/update', 'admin.SysSmsCaptchas/update')->allowCrossDomain();
Route::delete('/api/admin/sys-sms-captchas/delete', 'admin.SysSmsCaptchas/delete')->allowCrossDomain();

Route::get('/api/admin/sys-feedbacks/index', 'admin.SysFeedbacks/index')->allowCrossDomain();
Route::get('/api/admin/sys-feedbacks/read', 'admin.SysFeedbacks/read')->allowCrossDomain();
Route::post('/api/admin/sys-feedbacks/save', 'admin.SysFeedbacks/save')->allowCrossDomain();
Route::put('/api/admin/sys-feedbacks/update', 'admin.SysFeedbacks/update')->allowCrossDomain();
Route::delete('/api/admin/sys-feedbacks/delete', 'admin.SysFeedbacks/delete')->allowCrossDomain();

Route::get('/api/admin/sys-messages/index', 'admin.SysMessages/index')->allowCrossDomain();
Route::get('/api/admin/sys-messages/read', 'admin.SysMessages/read')->allowCrossDomain();
Route::post('/api/admin/sys-messages/save', 'admin.SysMessages/save')->allowCrossDomain();
Route::put('/api/admin/sys-messages/update', 'admin.SysMessages/update')->allowCrossDomain();
Route::delete('/api/admin/sys-messages/delete', 'admin.SysMessages/delete')->allowCrossDomain();

Route::get('/api/admin/sys-notices/index', 'admin.SysNotices/index')->allowCrossDomain();
Route::get('/api/admin/sys-notices/read', 'admin.SysNotices/read')->allowCrossDomain();
Route::post('/api/admin/sys-notices/save', 'admin.SysNotices/save')->allowCrossDomain();
Route::put('/api/admin/sys-notices/update', 'admin.SysNotices/update')->allowCrossDomain();
Route::delete('/api/admin/sys-notices/delete', 'admin.SysNotices/delete')->allowCrossDomain();

Route::get('/api/admin/sys-versions/index', 'admin.SysVersions/index')->allowCrossDomain();
Route::get('/api/admin/sys-versions/read', 'admin.SysVersions/read')->allowCrossDomain();
Route::post('/api/admin/sys-versions/save', 'admin.SysVersions/save')->allowCrossDomain();
Route::put('/api/admin/sys-versions/update', 'admin.SysVersions/update')->allowCrossDomain();
Route::delete('/api/admin/sys-versions/delete', 'admin.SysVersions/delete')->allowCrossDomain();

Route::get('/api/admin/users/index', 'admin.Users/index')->allowCrossDomain();
Route::get('/api/admin/users/read', 'admin.Users/read')->allowCrossDomain();
Route::post('/api/admin/users/save', 'admin.Users/save')->allowCrossDomain();
Route::put('/api/admin/users/update', 'admin.Users/update')->allowCrossDomain();
Route::delete('/api/admin/users/delete', 'admin.Users/delete')->allowCrossDomain();

Route::get('/api/admin/user-promoters/index', 'admin.UserPromoters/index')->allowCrossDomain();
Route::get('/api/admin/user-promoters/read', 'admin.UserPromoters/read')->allowCrossDomain();
Route::post('/api/admin/user-promoters/save', 'admin.UserPromoters/save')->allowCrossDomain();
Route::put('/api/admin/user-promoters/update', 'admin.UserPromoters/update')->allowCrossDomain();
Route::delete('/api/admin/user-promoters/delete', 'admin.UserPromoters/delete')->allowCrossDomain();

Route::get('/api/admin/user-levels/index', 'admin.UserLevels/index')->allowCrossDomain();
Route::get('/api/admin/user-levels/read', 'admin.UserLevels/read')->allowCrossDomain();
Route::post('/api/admin/user-levels/save', 'admin.UserLevels/save')->allowCrossDomain();
Route::put('/api/admin/user-levels/update', 'admin.UserLevels/update')->allowCrossDomain();
Route::delete('/api/admin/user-levels/delete', 'admin.UserLevels/delete')->allowCrossDomain();

Route::get('/api/admin/user-addresses/index', 'admin.UserAddresses/index')->allowCrossDomain();
Route::get('/api/admin/user-addresses/read', 'admin.UserAddresses/read')->allowCrossDomain();
Route::post('/api/admin/user-addresses/save', 'admin.UserAddresses/save')->allowCrossDomain();
Route::put('/api/admin/user-addresses/update', 'admin.UserAddresses/update')->allowCrossDomain();
Route::delete('/api/admin/user-addresses/delete', 'admin.UserAddresses/delete')->allowCrossDomain();

Route::get('/api/admin/goods/index', 'admin.Goods/index')->allowCrossDomain();
Route::get('/api/admin/goods/read', 'admin.Goods/read')->allowCrossDomain();
Route::post('/api/admin/goods/save', 'admin.Goods/save')->allowCrossDomain();
Route::put('/api/admin/goods/update', 'admin.Goods/update')->allowCrossDomain();
Route::delete('/api/admin/goods/delete', 'admin.Goods/delete')->allowCrossDomain();

Route::get('/api/admin/goods-advertisings/index', 'admin.GoodsAdvertisings/index')->allowCrossDomain();
Route::get('/api/admin/goods-advertisings/read', 'admin.GoodsAdvertisings/read')->allowCrossDomain();
Route::post('/api/admin/goods-advertisings/save', 'admin.GoodsAdvertisings/save')->allowCrossDomain();
Route::put('/api/admin/goods-advertisings/update', 'admin.GoodsAdvertisings/update')->allowCrossDomain();
Route::delete('/api/admin/goods-advertisings/delete', 'admin.GoodsAdvertisings/delete')->allowCrossDomain();

Route::get('/api/admin/postages/index', 'admin.Postages/index')->allowCrossDomain();
Route::get('/api/admin/postages/read', 'admin.Postages/read')->allowCrossDomain();
Route::post('/api/admin/postages/save', 'admin.Postages/save')->allowCrossDomain();
Route::put('/api/admin/postages/update', 'admin.Postages/update')->allowCrossDomain();
Route::delete('/api/admin/postages/delete', 'admin.Postages/delete')->allowCrossDomain();

Route::get('/api/admin/postage-2-merchants/index', 'admin.Postage2Merchants/index')->allowCrossDomain();
Route::get('/api/admin/postage-2-merchants/read', 'admin.Postage2Merchants/read')->allowCrossDomain();
Route::post('/api/admin/postage-2-merchants/save', 'admin.Postage2Merchants/save')->allowCrossDomain();
Route::put('/api/admin/postage-2-merchants/update', 'admin.Postage2Merchants/update')->allowCrossDomain();
Route::delete('/api/admin/postage-2-merchants/delete', 'admin.Postage2Merchants/delete')->allowCrossDomain();

Route::get('/api/admin/goods-comments/index', 'admin.GoodsComments/index')->allowCrossDomain();
Route::get('/api/admin/goods-comments/read', 'admin.GoodsComments/read')->allowCrossDomain();
Route::post('/api/admin/goods-comments/save', 'admin.GoodsComments/save')->allowCrossDomain();
Route::put('/api/admin/goods-comments/update', 'admin.GoodsComments/update')->allowCrossDomain();
Route::delete('/api/admin/goods-comments/delete', 'admin.GoodsComments/delete')->allowCrossDomain();

Route::get('/api/admin/goods-browsings/index', 'admin.GoodsBrowsings/index')->allowCrossDomain();
Route::get('/api/admin/goods-browsings/read', 'admin.GoodsBrowsings/read')->allowCrossDomain();
Route::post('/api/admin/goods-browsings/save', 'admin.GoodsBrowsings/save')->allowCrossDomain();
Route::put('/api/admin/goods-browsings/update', 'admin.GoodsBrowsings/update')->allowCrossDomain();
Route::delete('/api/admin/goods-browsings/delete', 'admin.GoodsBrowsings/delete')->allowCrossDomain();

Route::get('/api/admin/goods-favorites/index', 'admin.GoodsFavorites/index')->allowCrossDomain();
Route::get('/api/admin/goods-favorites/read', 'admin.GoodsFavorites/read')->allowCrossDomain();
Route::post('/api/admin/goods-favorites/save', 'admin.GoodsFavorites/save')->allowCrossDomain();
Route::put('/api/admin/goods-favorites/update', 'admin.GoodsFavorites/update')->allowCrossDomain();
Route::delete('/api/admin/goods-favorites/delete', 'admin.GoodsFavorites/delete')->allowCrossDomain();

Route::get('/api/admin/goods-categories/index', 'admin.GoodsCategories/index')->allowCrossDomain();
Route::get('/api/admin/goods-categories/read', 'admin.GoodsCategories/read')->allowCrossDomain();
Route::post('/api/admin/goods-categories/save', 'admin.GoodsCategories/save')->allowCrossDomain();
Route::put('/api/admin/goods-categories/update', 'admin.GoodsCategories/update')->allowCrossDomain();
Route::delete('/api/admin/goods-categories/delete', 'admin.GoodsCategories/delete')->allowCrossDomain();

Route::get('/api/admin/goods-brands/index', 'admin.GoodsBrands/index')->allowCrossDomain();
Route::get('/api/admin/goods-brands/read', 'admin.GoodsBrands/read')->allowCrossDomain();
Route::post('/api/admin/goods-brands/save', 'admin.GoodsBrands/save')->allowCrossDomain();
Route::put('/api/admin/goods-brands/update', 'admin.GoodsBrands/update')->allowCrossDomain();
Route::delete('/api/admin/goods-brands/delete', 'admin.GoodsBrands/delete')->allowCrossDomain();

Route::get('/api/admin/goods-specifications/index', 'admin.GoodsSpecifications/index')->allowCrossDomain();
Route::get('/api/admin/goods-specifications/read', 'admin.GoodsSpecifications/read')->allowCrossDomain();
Route::post('/api/admin/goods-specifications/save', 'admin.GoodsSpecifications/save')->allowCrossDomain();
Route::put('/api/admin/goods-specifications/update', 'admin.GoodsSpecifications/update')->allowCrossDomain();
Route::delete('/api/admin/goods-specifications/delete', 'admin.GoodsSpecifications/delete')->allowCrossDomain();

Route::get('/api/admin/goods-skus/index', 'admin.GoodsSkus/index')->allowCrossDomain();
Route::get('/api/admin/goods-skus/read', 'admin.GoodsSkus/read')->allowCrossDomain();
Route::post('/api/admin/goods-skus/save', 'admin.GoodsSkus/save')->allowCrossDomain();
Route::put('/api/admin/goods-skus/update', 'admin.GoodsSkus/update')->allowCrossDomain();
Route::delete('/api/admin/goods-skus/delete', 'admin.GoodsSkus/delete')->allowCrossDomain();

Route::get('/api/admin/goods-attributes/index', 'admin.GoodsAttributes/index')->allowCrossDomain();
Route::get('/api/admin/goods-attributes/read', 'admin.GoodsAttributes/read')->allowCrossDomain();
Route::post('/api/admin/goods-attributes/save', 'admin.GoodsAttributes/save')->allowCrossDomain();
Route::put('/api/admin/goods-attributes/update', 'admin.GoodsAttributes/update')->allowCrossDomain();
Route::delete('/api/admin/goods-attributes/delete', 'admin.GoodsAttributes/delete')->allowCrossDomain();

Route::get('/api/admin/attributes-2-goods/index', 'admin.Attributes2Goods/index')->allowCrossDomain();
Route::get('/api/admin/attributes-2-goods/read', 'admin.Attributes2Goods/read')->allowCrossDomain();
Route::post('/api/admin/attributes-2-goods/save', 'admin.Attributes2Goods/save')->allowCrossDomain();
Route::put('/api/admin/attributes-2-goods/update', 'admin.Attributes2Goods/update')->allowCrossDomain();
Route::delete('/api/admin/attributes-2-goods/delete', 'admin.Attributes2Goods/delete')->allowCrossDomain();

Route::get('/api/admin/goods-tags/index', 'admin.GoodsTags/index')->allowCrossDomain();
Route::get('/api/admin/goods-tags/read', 'admin.GoodsTags/read')->allowCrossDomain();
Route::post('/api/admin/goods-tags/save', 'admin.GoodsTags/save')->allowCrossDomain();
Route::put('/api/admin/goods-tags/update', 'admin.GoodsTags/update')->allowCrossDomain();
Route::delete('/api/admin/goods-tags/delete', 'admin.GoodsTags/delete')->allowCrossDomain();

Route::get('/api/admin/tags-2-goods/index', 'admin.Tags2Goods/index')->allowCrossDomain();
Route::get('/api/admin/tags-2-goods/read', 'admin.Tags2Goods/read')->allowCrossDomain();
Route::post('/api/admin/tags-2-goods/save', 'admin.Tags2Goods/save')->allowCrossDomain();
Route::put('/api/admin/tags-2-goods/update', 'admin.Tags2Goods/update')->allowCrossDomain();
Route::delete('/api/admin/tags-2-goods/delete', 'admin.Tags2Goods/delete')->allowCrossDomain();

Route::get('/api/admin/goods-coupons/index', 'admin.GoodsCoupons/index')->allowCrossDomain();
Route::get('/api/admin/goods-coupons/read', 'admin.GoodsCoupons/read')->allowCrossDomain();
Route::post('/api/admin/goods-coupons/save', 'admin.GoodsCoupons/save')->allowCrossDomain();
Route::put('/api/admin/goods-coupons/update', 'admin.GoodsCoupons/update')->allowCrossDomain();
Route::delete('/api/admin/goods-coupons/delete', 'admin.GoodsCoupons/delete')->allowCrossDomain();

Route::get('/api/admin/coupon-receiveds/index', 'admin.CouponReceiveds/index')->allowCrossDomain();
Route::get('/api/admin/coupon-receiveds/read', 'admin.CouponReceiveds/read')->allowCrossDomain();
Route::post('/api/admin/coupon-receiveds/save', 'admin.CouponReceiveds/save')->allowCrossDomain();
Route::put('/api/admin/coupon-receiveds/update', 'admin.CouponReceiveds/update')->allowCrossDomain();
Route::delete('/api/admin/coupon-receiveds/delete', 'admin.CouponReceiveds/delete')->allowCrossDomain();

Route::get('/api/admin/shopping-carts/index', 'admin.ShoppingCarts/index')->allowCrossDomain();
Route::get('/api/admin/shopping-carts/read', 'admin.ShoppingCarts/read')->allowCrossDomain();
Route::post('/api/admin/shopping-carts/save', 'admin.ShoppingCarts/save')->allowCrossDomain();
Route::put('/api/admin/shopping-carts/update', 'admin.ShoppingCarts/update')->allowCrossDomain();
Route::delete('/api/admin/shopping-carts/delete', 'admin.ShoppingCarts/delete')->allowCrossDomain();

Route::get('/api/admin/orders/index', 'admin.Orders/index')->allowCrossDomain();
Route::get('/api/admin/orders/read', 'admin.Orders/read')->allowCrossDomain();
Route::post('/api/admin/orders/save', 'admin.Orders/save')->allowCrossDomain();
Route::put('/api/admin/orders/update', 'admin.Orders/update')->allowCrossDomain();
Route::delete('/api/admin/orders/delete', 'admin.Orders/delete')->allowCrossDomain();

Route::get('/api/admin/order-details/index', 'admin.OrderDetails/index')->allowCrossDomain();
Route::get('/api/admin/order-details/read', 'admin.OrderDetails/read')->allowCrossDomain();
Route::post('/api/admin/order-details/save', 'admin.OrderDetails/save')->allowCrossDomain();
Route::put('/api/admin/order-details/update', 'admin.OrderDetails/update')->allowCrossDomain();
Route::delete('/api/admin/order-details/delete', 'admin.OrderDetails/delete')->allowCrossDomain();

Route::get('/api/admin/logistics-companies/index', 'admin.LogisticsCompanies/index')->allowCrossDomain();
Route::get('/api/admin/logistics-companies/read', 'admin.LogisticsCompanies/read')->allowCrossDomain();
Route::post('/api/admin/logistics-companies/save', 'admin.LogisticsCompanies/save')->allowCrossDomain();
Route::put('/api/admin/logistics-companies/update', 'admin.LogisticsCompanies/update')->allowCrossDomain();
Route::delete('/api/admin/logistics-companies/delete', 'admin.LogisticsCompanies/delete')->allowCrossDomain();

Route::get('/api/admin/log-crontabs/index', 'admin.LogCrontabs/index')->allowCrossDomain();
Route::get('/api/admin/log-crontabs/read', 'admin.LogCrontabs/read')->allowCrossDomain();
Route::post('/api/admin/log-crontabs/save', 'admin.LogCrontabs/save')->allowCrossDomain();
Route::put('/api/admin/log-crontabs/update', 'admin.LogCrontabs/update')->allowCrossDomain();
Route::delete('/api/admin/log-crontabs/delete', 'admin.LogCrontabs/delete')->allowCrossDomain();

Route::get('/api/admin/log-searches/index', 'admin.LogSearches/index')->allowCrossDomain();
Route::get('/api/admin/log-searches/read', 'admin.LogSearches/read')->allowCrossDomain();
Route::post('/api/admin/log-searches/save', 'admin.LogSearches/save')->allowCrossDomain();
Route::put('/api/admin/log-searches/update', 'admin.LogSearches/update')->allowCrossDomain();
Route::delete('/api/admin/log-searches/delete', 'admin.LogSearches/delete')->allowCrossDomain();

Route::get('/api/admin/log-orders/index', 'admin.LogOrders/index')->allowCrossDomain();
Route::get('/api/admin/log-orders/read', 'admin.LogOrders/read')->allowCrossDomain();
Route::post('/api/admin/log-orders/save', 'admin.LogOrders/save')->allowCrossDomain();
Route::put('/api/admin/log-orders/update', 'admin.LogOrders/update')->allowCrossDomain();
Route::delete('/api/admin/log-orders/delete', 'admin.LogOrders/delete')->allowCrossDomain();

Route::get('/api/admin/log-users/index', 'admin.LogUsers/index')->allowCrossDomain();
Route::get('/api/admin/log-users/read', 'admin.LogUsers/read')->allowCrossDomain();
Route::post('/api/admin/log-users/save', 'admin.LogUsers/save')->allowCrossDomain();
Route::put('/api/admin/log-users/update', 'admin.LogUsers/update')->allowCrossDomain();
Route::delete('/api/admin/log-users/delete', 'admin.LogUsers/delete')->allowCrossDomain();

Route::get('/api/admin/log-admins/index', 'admin.LogAdmins/index')->allowCrossDomain();
Route::get('/api/admin/log-admins/read', 'admin.LogAdmins/read')->allowCrossDomain();
Route::post('/api/admin/log-admins/save', 'admin.LogAdmins/save')->allowCrossDomain();
Route::put('/api/admin/log-admins/update', 'admin.LogAdmins/update')->allowCrossDomain();
Route::delete('/api/admin/log-admins/delete', 'admin.LogAdmins/delete')->allowCrossDomain();